home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gekikoh Dennoh Club 7
/
Gekikoh Dennoh Club Vol. 7 (Japan).7z
/
Gekikoh Dennoh Club Vol. 7 (Japan) (Track 01).bin
/
ikap
/
graphic1
/
bg_4
/
bg_48dm.bas
< prev
next >
Wrap
BASIC Source File
|
1999-06-15
|
2KB
|
83 lines
/*==== -: "BG_4_8.SP" デモプログラム :- ====
int i,j,fp,cd=0,ky,pb_n=7,pb_n2=3
int sc0,sc1,sc2,sc3,sy
dim char dat(8191)
dim str mes(3)={"1 9999990 9999990 2 9999990",
">>>>>>>>",
":",
":"}
/*==== -: Screen Init. :- ====
screen 0,3,1,1 : window(0,0,511,511)
vpage(&B0000) : apage(0)
v_priority("TGS")
v_special(2)
sp_init() : sp_disp(0)
bg_set(0,1,1) : bg_scroll(0, 0, 0)
bg_set(1,1,1) : bg_scroll(1, 0,256)
spfile_def("BG_48.SP",0)
palfile_def("BG_48.PAL",2) : PAL_CH() : PAL_CH2()
/*---- -: Map File Read :- ----
fp=fopen("BG_48DM.MAP","r")
fseek(fp,&H1E,0)
fread(dat,8192,fp)
fclose(fp)
/*---- -: Map Make :- ----
for i=0 to 63
for j=0 to 63
cd=dat( (i shl 7)+(j shl 1) ) shl 8
cd=cd+dat( (i shl 7)+(j shl 1)+1 )
bg_put(1,j,i,cd)
next
next
/*---- -: ??? :- ----
symbol( 1, 1,mes(0),1,1,1, 60,0)
symbol( 0, 0,mes(0),1,1,1,65534,0)
symbol( 1, 9,mes(1),1,1,1, 60,0)
symbol( 0, 8,mes(1),1,1,1,65534,0)
fill( 0,248,255,255,rgb(15,15,17)+1)
symbol( 0,248,mes(2),1,1,1,65534,0)
symbol(128,248,mes(3),1,1,1,65534,0)
/*---- -: スクロール カイシ :- ----
vpage(&B0001) : sp_disp(1)
while 1
sc0=sc0+1 and 1023
sc1=sc1+1 and 2047
ky=asc(inkey$(0))
if ky = &H1B then break
if ky = &H20 then PAL_CH()
if ky = &H42 or ky = &H62 then PAL_CH2()
v_disp()
bg_scroll(0,sc0 shr 1, 0)
/* bg_scroll(1,sc0,256)
bg_scroll(1,sc1 shr 2,256)
endwhile
end
/*---- -: palet change :- ----
func PAL_CH()
int i
pb_n=(pb_n+1) and 7
for i=0 to 15
sp_color(i,sp_color(i,,2+pb_n),1)
next
endfunc
func PAL_CH2()
int i
pb_n2=(pb_n2+1) and 3
for i=0 to 15
sp_color(i,sp_color(i,,10+pb_n2),15)
next
endfunc